//void, Obj owner

Hero this;
Query q;
ObjList ol_outpost;
int suc, k;

this = owner.AsHero();
if (!.IsValid) return;

q = ClassPlayerObjs("Outpost", .player);

while(.IsValid){
	if(!q.IsEmpty){
		ol_outpost = q.GetObjList();
        suc = ol_outpost.count * 10 + 10;
		if(GetUseCount != suc)
            SetUseCount(suc);
    }
	Sleep(3000);
	if(EnvReadInt(.player, "LeaderOfNation") != 1)
		EnvWriteInt(.player, "LeaderOfNation", 1);
	Sleep(30000); 
}

